#include <stdio.h>
#include "../manager/link.h"
#include "../manager/manager.h"
#include "../manager/iplugin.h"
#include "plugin2.h"


#ifdef WIN32
BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) {
    if (fdwReason == DLL_PROCESS_ATTACH) {
        static Plugin2 plugin;
        Manager::instance().add(&plugin);
        return TRUE;
    }
    return FALSE;
}
#endif

#ifdef __linux__
__attribute__((constructor)) void init()
{
    static Plugin2 plugin;
    Manager::instance().add(&plugin);
}
#endif
